<?php
    include_once 'modules/tuvi/views/HeaderView.php';
?>
<script type="text/javascript">
    function confirm_delete() {
      return confirm('Bạn có muốn xóa bản ghi này không?');
    }
</script>
<div class="grid">
    <div class="row">
        <?php
            include_once 'modules/tuvi/views/MenuView.php';
        ?>

        <div class="span9">
            <h2 id="_default"><i class="icon-accessibility on-left"></i><?php echo $act_title;?></h2>
            <div class="example">
                <form action="?mod=tuvi&act=listTuvi" method="post">
                    <div class="input-control text">
                        <input type="text" name="search" placeholder="Tìm kiếm" value="<?php echo $strSearch;?>" onkeyup="showHint(this.value)"/>
                        <button class="btn-search" name="btnSearch"></button>
                    </div>
                </form>
                <table class="table bordered hovered">
                    <thead>
                    <tr>
                        <th class="text-left">Tuổi</th>
                        <th class="text-left" width="50px">Xóa</th>
                    </tr>
                    </thead>
                    <tbody>
                    <?php if (count($list) > 0) {?>
                        <?php foreach ($list as $value) {?>
                        <tr>
                            <td><a href="?mod=tuvi&act=edit&id=<?php echo $value['id'];?>"><?php echo $value['ages'];?></a></td>
                            <td class="center"><a href="?mod=tuvi&act=delete&id=<?php echo $value['id'];?>" onclick="return confirm_delete()"><span class="icon-remove"></span></a></td>
                        </tr>
                        <?php }
                        }
                    ?>
                    </tbody>
                    <tfoot></tfoot>
                </table>
                <?php include_once 'layout/paging.php';?>
            </div>
        </div>
    </div>
</div>
<?php
    include_once 'layout/notice.php';
?>